package org.ams.log.service.impl;

import java.util.List;
import java.util.Map;

import javax.annotation.Resource;

import org.ams.log.dao.LoginLogDao;
import org.ams.log.entity.LoginLog;
import org.ams.log.service.LoginLogService;
import org.springframework.stereotype.Service;

@Service("loginLogService")
public class LoginLogServiceImpl implements LoginLogService {

	@Resource
	private LoginLogDao loginLogDao;
	
	@Override
	public void save(LoginLog loginLog) {
		loginLogDao.save(loginLog);
	}

	@Override
	public LoginLog queryLastLoginLogByAccountId(Integer accountId) {
		return loginLogDao.queryLastLoginLogByAccountId(accountId);
	}

	@Override
	public Integer queryLoginCountByAccountId(Integer accountId) {
		return loginLogDao.queryLoginCountByAccountId(accountId);
	}

	@Override
	public List<LoginLog> queryLoginLogListByPage(Map<String, Object> params) {
		return loginLogDao.queryLoginLogListByPage(params);
	}

}
